<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ taglib prefix="fmt" uri="http://java.sun.com/jstl/fmt_rt" %>
<!DOCTYPE html>
<html>
    <head>
        <meta charset="UTF-8">
        <title>限时秒杀</title>
        <meta content="width=device-width,initial-scale=1.0,maximum-scale=1.0,user-scalable=0" name="viewport"/>
        <meta content="yes" name="apple-mobile-web-app-capable"/>
        <meta content="black" name="apple-mobile-web-app-status-bar-style"/>
        <meta content="telephone=no" name="format-detection"/>
        <link href="/boot/seckill/css/style.css" rel="stylesheet" type="text/css"/>
        <script type="text/javascript" src="/boot/seckill/js/jquery.min.js"></script>
        <script type="text/javascript" src="/boot/seckill/js/tab.js"></script>
        <link href="/boot/css/bootstrap.css" rel="stylesheet">
        <link href="/boot/plugins/revolution/css/settings.css" rel="stylesheet" type="text/css"><!-- REVOLUTION SETTINGS STYLES -->
        <link href="/boot/plugins/revolution/css/layers.css" rel="stylesheet" type="text/css"><!-- REVOLUTION LAYERS STYLES -->
        <link href="/boot/plugins/revolution/css/navigation.css" rel="stylesheet" type="text/css"><!-- REVOLUTION NAVIGATION STYLES -->
        <link href="/boot/css/style.css" rel="stylesheet">
        <link href="/boot/css/responsive.css" rel="stylesheet">


        <link rel="shortcut icon" href="/boot/images/favicon.png" type="image/x-icon">
        <link rel="icon" href="/boot/images/favicon.png" type="image/x-icon">
    </head>
    <body>

    <jsp:include page="nav.jsp" flush="true"></jsp:include>
        <section class="aui-flexView">
            <header class="aui-navBar aui-navBar-fixed">
                <a href="javascript:;" class="aui-navBar-item">
                    <i class="icon icon-return"></i>
                </a>
                <div class="aui-center">
                    <span class="aui-center-title">限时秒杀</span>
                    <input type="text" value="${uname}" id="unamez">
                </div>
                <a href="javascript:;" class="aui-navBar-item">
                    <i class="icon icon-share"></i>
                </a>
            </header>
            <section class="aui-scrollView">
                <div class="aui-tab" data-ydui-tab>


                    <ul class="tab-nav b-line">


                        <li class="tab-nav-item tab-active1">
                            <a href="javascript:;">
                                <div>10:00</div>
                                <div>抢购中</div>
                            </a>
                        </li>
                        <li class="tab-nav-item tab-active2">
                            <a href="javascript:;">
                                <div>14:00</div>
                                <div>预约中</div>
                            </a>
                        </li>
                        <li class="tab-nav-item tab-active3">
                            <a href="javascript:;">
                                <div>18:00</div>
                                <div>预约中</div>
                            </a>
                        </li>
                        <li class="tab-nav-item tab-active4">
                            <a href="javascript:;">
                                <div>20:00</div>
                                <div>预约中</div>
                            </a>
                        </li>
                    </ul>







<%--                    <div class="tab-panel tab-panel-clear-line">--%>
<%--                        <div class="tab-panel-item tab-active1">--%>
<%--                            <div class="aui-flex b-line">--%>
<%--                                <div class="aui-flex-box">--%>
<%--                                    <p>抢购中 数量有限下单先得哦</p>--%>
<%--                                </div>--%>



<%--                                <div class="aui-limit-time clearfix">--%>
<%--                                    <div class="aui-fl-time">距结束</div>--%>
<%--                                    <div class="time-item">--%>
<%--                                        <span class="hour_show">0<s id="h"></s>4 </span>--%>
<%--                                        <em>:</em>--%>
<%--                                        <span class="minute_show"><s></s>09 </span>--%>
<%--                                        <em>:</em>--%>
<%--                                        <span class="second_show"><s></s>44 </span>--%>
<%--                                    </div>--%>
<%--                                </div>--%>




<%--                            </div>--%>
<%--                            <c:forEach  items="${webSeckillList}" var="w">--%>
<%--                                <a href="javascript:;" class="aui-flex b-line">--%>

<%--                                    <div class="aui-flex-time-img">--%>
<%--                                        <img src="/boot/seckill/images/img-ad-001.png" alt="">--%>
<%--                                    </div>--%>
<%--                                    <div class="aui-flex-box">--%>
<%--                                    <span>--%>
<%--                                        <c:forEach items="${carDetailsList}" var="c">--%>
<%--                                            <c:forEach items="${carBrandsList}" var="b">--%>
<%--                                                <c:if test="${w.productId == c.id && c.brId == b.id}"> <h2>${b.brName}</h2></c:if>--%>
<%--                                            </c:forEach>--%>
<%--                                        </c:forEach>--%>
<%--                                    </span>--%>
<%--                                        <span>--%>
<%--                                        <c:forEach items="${carDetailsList}" var="c">--%>
<%--                                            <c:forEach items="${carStylesList}" var="s">--%>
<%--                                                <c:if test="${w.productId == c.id && c.stId == s.id}"> <h2>${s.stName}</h2></c:if>--%>
<%--                                            </c:forEach>--%>
<%--                                        </c:forEach>--%>
<%--                                    </span>--%>
<%--                                        <div class="aui-flex-tag">--%>
<%--                                            <span>ID:${w.id}</span>--%>
<%--                                            <span>开始的时间:<fmt:formatDate value="${w.startTime}" pattern="yyyy-MM-dd "/>--%>
<%--                                        </span>--%>
<%--                                            <span>结束的时间:<fmt:formatDate value="${w.endTime}" pattern="yyyy-MM-dd "/>--%>
<%--                                        </span>--%>

<%--                                        </div>--%>
<%--                                        <div class="aui-time-seep ">--%>
<%--                                            <div class="aui-time-seep-go" style="width:88%"></div>--%>
<%--                                            <span>秒杀名额${w.num}</span>--%>
<%--                                        </div>--%>
<%--                                        <div class="aui-text-bottom">--%>
<%--                                            <h3>￥${w.seckillPrice}--%>
<%--                                            </h3>--%>
<%--                                            <h4>--%>
<%--                                                    &lt;%&ndash;                                            <c:forEach items="carDetailsList" var="c">&ndash;%&gt;--%>
<%--                                                    &lt;%&ndash;                                                <c:if test="${c.cCus}"></c:if>&ndash;%&gt;--%>
<%--                                                    &lt;%&ndash;                                            </c:forEach>&ndash;%&gt;--%>
<%--                                            </h4>--%>
<%--                                        </div>--%>
<%--                                        <div class="aui-time-button">--%>
<%--                                            <c:if test="${w.status == 2}">--%>
<%--                                                <button>抢购</button>--%>
<%--                                            </c:if>--%>
<%--                                            <c:if test="${w.status == 1}">--%>
<%--                                                <button>已结束</button>--%>
<%--                                            </c:if>--%>
<%--                                            <button>抢购</button>--%>
<%--                                        </div>--%>
<%--                                    </div>--%>
<%--                                </a>--%>
<%--                            </c:forEach>--%>

<%--                        </div>--%>
<%--                        </a>--%>
<%--                    </div>--%>





                    <div class="tab-panel tab-panel-clear-line">
                        <div class="tab-panel-item tab-active2">
                            <div class="aui-flex b-line">
                                <div class="aui-flex-box">
                                    <p>抢购中 数量有限下单先得哦</p>
                                </div>

                                <div  style="margin-left: 0px;width: 300px;height: 50px;">
                                    <h3>距离开始</h3>
                                    <div id="time1">
                                        <span id="day1">**天</span>
                                        <strong><span id="hour1">**时</span></strong>
                                        <strong><span id="minute1">**分</span></strong>
                                        <strong><span id="second1">**秒</span></strong>
                                    </div>
                                </div>



                                <div style="margin-left: 0px;width: 300px;height: 50px;">
                                    <h3>距离结束</h3>
                                    <div id="time">
                                        <span id="day">**天</span>
                                        <strong><span id="hour">**时</span></strong>
                                        <strong><span id="minute">**分</span></strong>
                                        <strong><span id="second">**秒</span></strong>
                                    </div>
                                </div>
                                <script src="/boot/js/dj.js"></script>



<%--                                <div class="aui-limit-time clearfix">--%>
<%--                                    <div class="aui-fl-time">距结束</div>--%>
<%--                                    <div class="time-item">--%>
<%--                                        <span class="hour_show">0<s id="h"></s>4 </span>--%>
<%--                                        <em>:</em>--%>
<%--                                        <span class="minute_show"><s></s>09 </span>--%>
<%--                                        <em>:</em>--%>
<%--                                        <span class="second_show"><s></s>44 </span>--%>
<%--                                    </div>--%>
<%--                                </div>--%>




                            </div>
                            <c:forEach  items="${webSeckillList}" var="w">
                            <a href="javascript:;" class="aui-flex b-line">

                                <div class="aui-flex-time-img">
                                    <img src="/boot/seckill/images/img-ad-001.png" alt="" onclick="seckilldetail(${w.id})">
                                </div>
                                <div class="aui-flex-box">
                                    <span>
                                        <c:forEach items="${carDetailsList}" var="c">
                                            <c:forEach items="${carBrandsList}" var="b">
                                               <c:if test="${w.productId == c.id && c.brId == b.id}">

                                                   <h2>${b.brName}</h2>

                                               </c:if>
                                            </c:forEach>
                                        </c:forEach>
                                    </span>
                                    <span>
                                        <c:forEach items="${carDetailsList}" var="c">
                                            <c:forEach items="${carStylesList}" var="s">
                                                <c:if test="${w.productId == c.id && c.stId == s.id}"> <h2>${s.stName}</h2></c:if>
                                            </c:forEach>
                                        </c:forEach>
                                    </span>
                                    <div class="aui-flex-tag">
                                        <span name="id" value="${w.id}">ID:${w.id}</span>
                                        <span>开始的时间:<fmt:formatDate value="${w.startTime}" pattern="yyyy-MM-dd HH:mm:ss"/>
                                        </span>
                                        <span>结束的时间:<fmt:formatDate value="${w.endTime}" pattern="yyyy-MM-dd HH:mm:ss"/>
                                        </span>
                                        &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
                                        <span>     <c:if test="${w.num>0}">
                                            秒杀名额${w.num}</span>
                                        </c:if>
                                        <c:if test="${w.num==0}">
                                            已售空
                                        </c:if></span>

                                    </div>
                                    <div class="aui-time-seep ">
                                        <div class="aui-time-seep-go" style="width:88%"></div>
                                        <br>

                                    </div>
                                    <div class="aui-text-bottom">
                                        <input type="text" value="${w.seckillPrice}" id="pricezz">
                                        </h3>
                                        <h4>
<%--                                            <c:forEach items="carDetailsList" var="c">--%>
<%--                                                <c:if test="${c.cCus}"></c:if>--%>
<%--                                            </c:forEach>--%>
                                        </h4>
                                    </div>
                                    <div class="aui-time-button">
                                        <c:if test="${w.status == 2}">
                                            已结束
                                        </c:if>
                                        <c:if test="${w.status == 1}">
                                            正在热销
                                        </c:if>

<%--                                        <c:if test="${w.num}>0">--%>
                                            <button type="button" onclick="buy(${w.id})">抢购</button>
<%--                                        </c:if>--%>
<%--                                        <c:if test="${w.num}=0">--%>
<%--                                            <button type="button" onclick="buy(${w.id})" disabled="disabled">已售空</button>--%>
<%--                                        </c:if>--%>


                                    </div>
                                </div>
                            </a>
                            </c:forEach>

                                </div>
                            </a>
                        </div>







<%--                    <div class="tab-panel tab-panel-clear-line">--%>
<%--                        <div class="tab-panel-item tab-active3">--%>
<%--                            <div class="aui-flex b-line">--%>
<%--                                <div class="aui-flex-box">--%>
<%--                                    <p>抢购中 数量有限下单先得哦</p>--%>
<%--                                </div>--%>



<%--                                <div class="aui-limit-time clearfix">--%>
<%--                                    <div class="aui-fl-time">距结束</div>--%>
<%--                                    <div class="time-item">--%>
<%--                                        <span class="hour_show">0<s id="h"></s>4 </span>--%>
<%--                                        <em>:</em>--%>
<%--                                        <span class="minute_show"><s></s>09 </span>--%>
<%--                                        <em>:</em>--%>
<%--                                        <span class="second_show"><s></s>44 </span>--%>
<%--                                    </div>--%>
<%--                                </div>--%>




<%--                            </div>--%>
<%--                            <c:forEach  items="${webSeckillList}" var="w">--%>
<%--                                <a href="javascript:;" class="aui-flex b-line">--%>

<%--                                    <div class="aui-flex-time-img">--%>
<%--                                        <img src="/boot/seckill/images/img-ad-001.png" alt="">--%>
<%--                                    </div>--%>
<%--                                    <div class="aui-flex-box">--%>
<%--                                    <span>--%>
<%--                                        <c:forEach items="${carDetailsList}" var="c">--%>
<%--                                            <c:forEach items="${carBrandsList}" var="b">--%>
<%--                                                <c:if test="${w.productId == c.id && c.brId == b.id}"> <h2>${b.brName}</h2></c:if>--%>
<%--                                            </c:forEach>--%>
<%--                                        </c:forEach>--%>
<%--                                    </span>--%>
<%--                                        <span>--%>
<%--                                        <c:forEach items="${carDetailsList}" var="c">--%>
<%--                                            <c:forEach items="${carStylesList}" var="s">--%>
<%--                                                <c:if test="${w.productId == c.id && c.stId == s.id}"> <h2>${s.stName}</h2></c:if>--%>
<%--                                            </c:forEach>--%>
<%--                                        </c:forEach>--%>
<%--                                    </span>--%>
<%--                                        <div class="aui-flex-tag">--%>
<%--                                            <span>ID:${w.id}</span>--%>
<%--                                            <span>开始的时间:<fmt:formatDate value="${w.startTime}" pattern="yyyy-MM-dd "/>--%>
<%--                                        </span>--%>
<%--                                            <span>结束的时间:<fmt:formatDate value="${w.endTime}" pattern="yyyy-MM-dd "/>--%>
<%--                                        </span>--%>

<%--                                        </div>--%>
<%--                                        <div class="aui-time-seep ">--%>
<%--                                            <div class="aui-time-seep-go" style="width:88%"></div>--%>
<%--                                            <span>秒杀名额${w.num}</span>--%>
<%--                                        </div>--%>
<%--                                        <div class="aui-text-bottom">--%>
<%--                                            <h3>￥${w.seckillPrice}--%>
<%--                                            </h3>--%>
<%--                                            <h4>--%>
<%--                                                    &lt;%&ndash;                                            <c:forEach items="carDetailsList" var="c">&ndash;%&gt;--%>
<%--                                                    &lt;%&ndash;                                                <c:if test="${c.cCus}"></c:if>&ndash;%&gt;--%>
<%--                                                    &lt;%&ndash;                                            </c:forEach>&ndash;%&gt;--%>
<%--                                            </h4>--%>
<%--                                        </div>--%>
<%--                                        <div class="aui-time-button">--%>
<%--                                            <c:if test="${w.status == 2}">--%>
<%--                                                <button>抢购</button>--%>
<%--                                            </c:if>--%>
<%--                                            <c:if test="${w.status == 1}">--%>
<%--                                                <button>已结束</button>--%>
<%--                                            </c:if>--%>
<%--                                            <button>抢购</button>--%>
<%--                                        </div>--%>
<%--                                    </div>--%>
<%--                                </a>--%>
<%--                            </c:forEach>--%>

<%--                        </div>--%>
<%--                        </a>--%>
<%--                    </div>--%>







<%--                    <div class="tab-panel tab-panel-clear-line">--%>
<%--                        <div class="tab-panel-item tab-active4">--%>
<%--                            <div class="aui-flex b-line">--%>
<%--                                <div class="aui-flex-box">--%>
<%--                                    <p>抢购中 数量有限下单先得哦</p>--%>
<%--                                </div>--%>



<%--                                <div class="aui-limit-time clearfix">--%>
<%--                                    <div class="aui-fl-time">距结束</div>--%>
<%--                                    <div class="time-item">--%>
<%--                                        <span class="hour_show">0<s id="h"></s>4 </span>--%>
<%--                                        <em>:</em>--%>
<%--                                        <span class="minute_show"><s></s>09 </span>--%>
<%--                                        <em>:</em>--%>
<%--                                        <span class="second_show"><s></s>44 </span>--%>
<%--                                    </div>--%>
<%--                                </div>--%>




<%--                            </div>--%>
<%--                            <c:forEach  items="${webSeckillList}" var="w">--%>
<%--                                <a href="javascript:;" class="aui-flex b-line">--%>

<%--                                    <div class="aui-flex-time-img">--%>
<%--                                        <img src="/boot/seckill/images/img-ad-001.png" alt="" ">--%>
<%--                                    </div>--%>
<%--                                    <div class="aui-flex-box">--%>
<%--                                    <span>--%>
<%--                                        <c:forEach items="${carDetailsList}" var="c">--%>
<%--                                            <c:forEach items="${carBrandsList}" var="b">--%>
<%--                                                <c:if test="${w.productId == c.id && c.brId == b.id}"> <h2>${b.brName}</h2></c:if>--%>
<%--                                            </c:forEach>--%>
<%--                                        </c:forEach>--%>
<%--                                    </span>--%>
<%--                                        <span>--%>
<%--                                        <c:forEach items="${carDetailsList}" var="c">--%>
<%--                                            <c:forEach items="${carStylesList}" var="s">--%>
<%--                                                <c:if test="${w.productId == c.id && c.stId == s.id}"> <h2>${s.stName}</h2></c:if>--%>
<%--                                            </c:forEach>--%>


<%--                                        </c:forEach>--%>
<%--                                    </span>--%>
<%--                                        <div class="aui-flex-tag">--%>
<%--                                            <span>ID:${w.id}</span>--%>
<%--                                            <span>开始的时间:<fmt:formatDate value="${w.startTime}" pattern="yyyy-MM-dd "/>--%>
<%--                                        </span>--%>
<%--                                            <span>结束的时间:<fmt:formatDate value="${w.endTime}" pattern="yyyy-MM-dd "/>--%>
<%--                                        </span>--%>

<%--                                        </div>--%>





<%--                                        <div class="aui-time-seep ">--%>
<%--&lt;%&ndash;                                            <div class="aui-time-seep-go" style="width:88%"></div>&ndash;%&gt;--%>


<%--                                        </div>--%>


<%--                                        <div class="aui-text-bottom">--%>
<%--                                            <h3><input value="￥${w.seckillPrice}" id="pricexx">--%>
<%--                                            </h3>--%>
<%--                                            <h4>--%>
<%--                                                    &lt;%&ndash;                                            <c:forEach items="carDetailsList" var="c">&ndash;%&gt;--%>
<%--                                                    &lt;%&ndash;                                                <c:if test="${c.cCus}"></c:if>&ndash;%&gt;--%>
<%--                                                    &lt;%&ndash;                                            </c:forEach>&ndash;%&gt;--%>
<%--                                            </h4>--%>
<%--                                        </div>--%>
<%--                                        <div class="aui-time-button">--%>
<%--                                            <c:if test="${w.status == 2}">--%>
<%--                                                <button>抢购</button>--%>
<%--                                            </c:if>--%>
<%--                                            <c:if test="${w.status == 1}">--%>
<%--                                                <button>已结束</button>--%>
<%--                                            </c:if>--%>
<%--                                            <button>抢购</button>--%>
<%--                                        </div>--%>
<%--                                    </div>--%>
<%--                                </a>--%>
<%--                            </c:forEach>--%>


<%--                        </div>--%>
<%--                        </a>--%>
<%--                    </div>--%>
]

                    </div>
                </div>

            </section>
        </section>

<%--        <script src="/boot/js/jquery.js"></script>--%>
<%--        <script type="text/javascript">--%>


    <script>





        var daySpan = my$('day');
        var hourSpan = my$('hour');
        var minuteSpan = my$('minute');
        var secondSpan = my$('second');
        TimeRow();
        setInterval(TimeRow, 1000)

        function TimeRow() {
            var end = new Date('2021-5-20 14:28:0');
            var start = new Date();
            var time = getInterval(start, end);
            setInnerText(daySpan, time.day+'天');
            setInnerText(hourSpan, time.hour+'时');
            setInnerText(minuteSpan, time.minute+'分');
            setInnerText(secondSpan, time.second+'秒');
        }



        var daySpan1 = my$('day1');
        var hourSpan1 = my$('hour1');
        var minuteSpan1 = my$('minute1');
        var secondSpan1 = my$('second1');
        TimeRow1();
        setInterval(TimeRow1, 1000)

        function TimeRow1() {
            var end1 = new Date('2021-5-20 14:00:0');
            var start1 = new Date();
            var time = getInterval(start1, end1);
            setInnerText(daySpan1, time.day+'天');
            setInnerText(hourSpan1, time.hour+'时');
            setInnerText(minuteSpan1, time.minute+'分');
            setInnerText(secondSpan1, time.second+'秒');
        }










    </script>

<%--            var date = new Date();--%>
<%--            var todayYear = date.getFullYear();--%>
<%--            var todayMonth = date.getMonth();--%>
<%--            var today = date.getDate();--%>
<%--            //获取当天的开始时间--%>
<%--            new  Date(todayYear ,todayMonth,today,'00','00','00');--%>
<%--            //获取当天的结束时间--%>
<%--            new  Date(todayYear ,todayMonth,today,'23','59','59');--%>
<%--            //包括当前时间，三天内--%>
<%--            new  Date(todayYear ,todayMonth,today-2,'00','00','00');--%>


<%--            // var intDiff = parseInt((new Date(new Date()+24*60*60*1000).getTime()-new Date().getTime()));--%>
<%--            // new Date(new Date().toLocaleDateString())--%>
<%--            var intDiff = parseInt((new Date().getTime()-new Date(new Date().toDateString()).getTime()));--%>
<%--            //  var intDiff = parseInt(new Date().getTime()-10*)--%>
<%--             console.log(intDiff);--%>
<%--            //倒计时总秒数量--%>

<%--            function timer(intDiff) {--%>
<%--                window.setInterval(function() {--%>
<%--                    var day = 00--%>
<%--                        , hour = 00--%>
<%--                        , minute = 00--%>
<%--                        , second = 00;--%>
<%--                    //时间默认值--%>
<%--                    if (intDiff > 0) {--%>
<%--                        day = Math.floor(intDiff / (60 * 60 * 24));--%>
<%--                        hour = Math.floor(intDiff / (60 * 60)) - (day * 24);--%>
<%--                        minute = Math.floor(intDiff / 60) - (day * 24 * 60) - (hour * 60);--%>
<%--                        second = Math.floor(intDiff) - (day * 24 * 60 * 60) - (hour * 60 * 60) - (minute * 60);--%>
<%--                    }--%>
<%--                    if (minute <= 9)--%>
<%--                        minute = '0' + minute;--%>
<%--                    if (second <= 9)--%>
<%--                        second = '0' + second;--%>
<%--                    $('.hour_show').html('0<s id="h"></s>' + hour + ' ');--%>
<%--                    $('.minute_show').html('<s></s>' + minute + ' ');--%>
<%--                    $('.second_show').html('<s></s>' + second + ' ');--%>
<%--                    intDiff--;--%>
<%--                }, 1000);--%>
<%--            }--%>

<%--            $(function() {--%>
<%--                timer(intDiff);--%>
<%--            });--%>
<%--        </script>--%>

    </body>

    <script src="/boot/plugins/revolution/js/jquery.themepunch.revolution.min.js"></script>
    <script src="/boot/plugins/revolution/js/jquery.themepunch.tools.min.js"></script>
    <script src="/boot/plugins/revolution/js/extensions/revolution.extension.actions.min.js"></script>
    <script src="/boot/plugins/revolution/js/extensions/revolution.extension.carousel.min.js"></script>
    <script src="/boot/plugins/revolution/js/extensions/revolution.extension.kenburn.min.js"></script>
    <script src="/boot/plugins/revolution/js/extensions/revolution.extension.layeranimation.min.js"></script>
    <script src="/boot/plugins/revolution/js/extensions/revolution.extension.migration.min.js"></script>
    <script src="/boot/plugins/revolution/js/extensions/revolution.extension.navigation.min.js"></script>
    <script src="/boot/plugins/revolution/js/extensions/revolution.extension.parallax.min.js"></script>
    <script src="/boot/plugins/revolution/js/extensions/revolution.extension.slideanims.min.js"></script>
    <script src="/boot/plugins/revolution/js/extensions/revolution.extension.video.min.js"></script>
    <script src="/boot/js/main-slider-script.js"></script>

    <script src="/boot/js/jquery-ui.js"></script>
    <script src="/boot/js/jquery.fancybox.pack.js"></script>
    <script src="/boot/js/jquery.fancybox-media.js"></script>
    <script src="/boot/js/owl.js"></script>
    <script src="/boot/js/appear.js"></script>
    <script src="/boot/js/wow.js"></script>
    <script src="/boot/js/main-slider-script.js"></script>
    <script src="/boot/js/script.js"></script>
<script>

    function seckilldetail(wid) {

        // let price = document.getElementById("price").value;
        <%--     let  id = ${w.id};--%>

             alert(wid);

             window.location="/boot/user/seckilldetail?wid="+wid;

    }

    function buy(obj) {
        // alert(obj);
        let id = obj;
        alert(obj);
        let name = 11111;
        // let prices = document.getElementById("pricezz").value;
        // alert(prices)
        let uname = document.getElementById("unamez").value;

        $.post('/boot/sec',{uname:uname,id:id},function (data) {

            if(data.code =="200")
            {
                alert("恭喜大大抢购成功");
                window.location="/boot/user/seckill-list?name="+name+"&id="+id;
            }
            if(data.code == "4")
            {
                alert("您已经抢购成功了，大人把机会留给手速慢的小伙伴吧");

            }
            if(data.code == "0")
            {
                alert("大人还没开始呢，耐心等待哦");


            }
            if(data.code == "2")
            {
                alert("又睡过了吧，秒杀都结束了哦");

            }
            if(data.code == "3")
            {
                alert("啊啊啊。好遗憾好可惜，秒杀商品已经卖光了，下次记得蹲点哦");

            }

        })

    }


</script>


</html>
